package com.aisile.admin.feign;

import com.aisile.model.article.pojos.ApArticle;
import com.aisile.model.article.pojos.ApArticleConfig;
import com.aisile.model.article.pojos.ApArticleContent;
import com.aisile.model.article.pojos.ApAuthor;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

/**
 * @Auther:yry
 * @Date:2024/1/10 0010
 * @VERSON:1.0
 */
@FeignClient("leadnews-article")
public interface ArticleFeign {

    @PostMapping("/api/v1/article/save")
    public ApArticle saveArticle(@RequestBody ApArticle apArticle);

    @GetMapping("/api/v1/author/findByWmUserId/{wmUserId}")
    public ApAuthor findByWmUserId(@PathVariable("wmUserId") Integer wmUserId);

    @PostMapping("/api/v1/article_content/save")
    public ApArticleContent saveApArticleContent(@RequestBody ApArticleContent apArticleContent);

    @PostMapping("/api/v1/article_config/save")
    public ApArticleConfig saveApArticleConfig(@RequestBody ApArticleConfig apArticleConfig);
}
